//
//  MainModuleAPI.m
//  Pods
//
//  Created by MoDao-iOS on 2017/7/14.
//
//

#import "MainModuleAPI.h"
#import "XMGTabBar.h"
#import "XMGTabBarController.h"
#import "XMGNavBar.h"
#import "XMGMiddleView.h"

@implementation MainModuleAPI

+ (XMGTabBarController *)rootTabBarCcontroller {
    return [XMGTabBarController shareInstance];
}

+ (void)addChildVC:(UIViewController *)vc normalImageName:(NSString *)normalImageName selectedImageName:(NSString *)selectedImageName isRequiredNavController:(BOOL)isRequired {
    [[XMGTabBarController shareInstance] addChildVC:vc normalImageName:normalImageName selectedImageName:selectedImageName isRequiredNavController:isRequired];
}

+ (void)setTabbarMiddleBtnClick: (void(^)(BOOL isPlaying))middleClickBlock {
    XMGTabBar *tabbar = (XMGTabBar *)[XMGTabBarController shareInstance].tabBar;
    tabbar.middleClickBlock = middleClickBlock;
}

+ (void)setNavBarGlobalBackGroundImage: (UIImage *)globalImg {
    [XMGNavBar setGlobalBackGroundImage:globalImg];
}

+ (void)setNavBarGlobalTextColor:(UIColor *)globalTextColor andFontSize:(CGFloat)fontSize {
    [XMGNavBar setGlobalTextColor:globalTextColor andFontSize:fontSize];
}

+ (UIView *)middleView {
    return [XMGMiddleView middleView];
}

@end
